import 'package:basic_library/basic_library.dart';
import 'package:flutter/material.dart';

///
/// 文本选择
///
class QSelectText extends StatelessWidget {
  const QSelectText({
    Key? key,
    this.isSelect = true,
    this.title,
    this.defaultStyle = StandardTextStyle.bigWithOpacity,
    this.selectStyle = StandardTextStyle.big,
    this.verticalHeight,
  }) : super(key: key);

  final bool isSelect;
  final String? title;
  final TextStyle? defaultStyle;
  final TextStyle? selectStyle;
  final double? verticalHeight;

  @override
  Widget build(BuildContext context) {
    return Container(
      padding: EdgeInsets.symmetric(vertical: verticalHeight ?? 10),
      color: Colors.black.withOpacity(0),
      child: Text(
        title ?? '??',
        textAlign: TextAlign.center,
        style:
            isSelect ? selectStyle : defaultStyle,
      ),
    );
  }
}
